/**
 * 
 */
package evolution.mlp.functions;

/**
 * @author camille
 * 
 */
public class Linear implements Function {

	private static Linear singleton;

	private Linear() {
		// nothing...
	}

	public static Linear getInstance() {
		if (singleton == null) {
			singleton = new Linear();
		}

		return singleton;
	}

	/*
	 * (non-Javadoc)
	 * 
	 * @see mlp.functions.Function#eval(double)
	 */
	@Override
	public double eval(double x) {
		return x;
	}

}
